<?php
include($_SERVER["DOCUMENT_ROOT"] . "/bob.php");
//include($_SERVER["DOCUMENT_ROOT"] . "/fonctions_mysqli.php");
include($_SERVER["DOCUMENT_ROOT"] . "/fonctions_globales.php");

$mysqli = new_mysqli($host, $user, $password, $database); //connection à la DB
$variable_get = filter_input_array(INPUT_GET);
//var_dump($variable_get);
$rqt_username = "SELECT * FROM inscription_questions WHERE id_question=".trim($mysqli->real_escape_string($variable_get['id_question']));
$result=  mysqli_query_with_error($mysqli, $rqt_username)->fetch_array();
$t_reponses=explode(';',$result['reponses']);
$trouve=false;
$i=0;
while($i<count($t_reponses) && $trouve==false){
    //echo strtolower($t_reponses[$i]).'<br/>';
    if(strtolower($t_reponses[$i])==strtolower($variable_get['reponse'])){
        $trouve=true;
    }
    $i++;
}
if ($trouve==false){
    echo 'FAUX';
}else{
    echo 'VRAI';
}



